import java.util.Collection;
import java.util.HashMap;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.ConcurrentMap;

class Scrabble {

//    ```plain
//    Letter                           Value
//    A, E, I, O, U, L, N, R, S, T       1
//    D, G                               2
//    B, C, M, P                         3
//    F, H, V, W, Y                      4
//    K                                  5
//    J, X                               8
//    Q, Z                               10
//            ```
    private static final Map<String, Integer> LetterMap = new HashMap<String, Integer>();
    static{
        LetterMap.put("A", 1);
        LetterMap.put("B", 3);
        LetterMap.put("C", 3);
        LetterMap.put("D", 2);
        LetterMap.put("E", 1);
        LetterMap.put("F", 4);
        LetterMap.put("G", 2);
        LetterMap.put("H", 4);
        LetterMap.put("I", 1);
        LetterMap.put("J", 8);
        LetterMap.put("K", 5);
        LetterMap.put("L", 1);
        LetterMap.put("M", 3);
        LetterMap.put("N", 1);
        LetterMap.put("O", 1);
        LetterMap.put("P", 3);
        LetterMap.put("Q", 10);
        LetterMap.put("R", 1);
        LetterMap.put("S", 1);
        LetterMap.put("T", 1);
        LetterMap.put("U", 1);
        LetterMap.put("V", 4);
        LetterMap.put("W", 4);
        LetterMap.put("X", 8);
        LetterMap.put("Y", 4);
        LetterMap.put("Z", 10);
    }

    private String word;

    Scrabble(String word) {
        this.word = word.toUpperCase();
    }

    int getScore() {
        int sum = 0;
        for (int i = 0; i < this.word.length(); i++) {
            sum += LetterMap.getOrDefault(this.word.substring(i, i+1), 0);
        }

        return sum;
    }

}
